package com.flyduck.vueshop.system.feign;

import com.flyduck.vueshop.common.core.lang.Result;
import com.flyduck.vueshop.system.vo.RemoteMenuRespVO;
import com.flyduck.vueshop.system.fallback.RemoteMenuFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * <p>
 * SysUserFeignClient
 * </p>
 *
 * @author flyduck
 * @since 2024-07-09
 */
@FeignClient(name = "vueshop-service-system",contextId = "remoteMenuFeignClient",fallback = RemoteMenuFallback.class)
public interface RemoteMenuFeignClient {
    @GetMapping("/system/remote/menu/getPermissionListByUserId")
    Result<List<String>> getPermissionListByUserId(@RequestParam("userId") Long userId);

    @GetMapping("/system/remote/menu/getEnableMenuListByUserId")
    Result<List<RemoteMenuRespVO>> getEnableMenuListByUserId(@RequestParam("userId") Long userId);

    @GetMapping("/system/remote/menu/getEnableMenuList")
    Result<List<RemoteMenuRespVO>> getEnableMenuList();
}
